package com.cq.hd.member.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * <p>
 * 提现记录表
 * </p>
 *
 * @author mYunYu
 * @since 2024-01-28
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("tb_withdrawal_bill")
@ApiModel(value = "TbWithdrawalBillPo对象", description = "提现记录表")
public class TbWithdrawalBillPo implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "商家资金账户类型(1:自建资金账户 2:平台资金账户)")
    private Integer businessFinancialAccountType;

    @ApiModelProperty(value = "商户资金账户类型(1:自建资金账户 2:平台资金账户)")
    private Integer merchantFinancialAccountType;

    @ApiModelProperty(value = "申请单号")
    @TableField("apply_no")
    private String applyNo;

    @ApiModelProperty(value = "提现用户id/商户id")
    @TableField("withdrawal_user_id")
    private Long withdrawalUserId;

    @ApiModelProperty(value = "所属商家id(商户补贴存在)")
    @TableField("business_id")
    private Long businessId;

    @ApiModelProperty(value = "提现类型(1-商户本金提现，2-佣金提现，3-商户补贴提现)")
    @TableField("withdrawal_type")
    private Integer withdrawalType;

    @ApiModelProperty(value = "银行卡账户名称")
    @TableField("card_name")
    private String cardName;

    @ApiModelProperty(value = "银行卡卡号")
    @TableField("card_no")
    private String cardNo;

    @ApiModelProperty(value = "开户银行")
    @TableField("bank_name")
    private String bankName;

    @ApiModelProperty(value = "变动前余额")
    @TableField("before_amt")
    private BigDecimal beforeAmt;

    @ApiModelProperty(value = "提现金额")
    @TableField("trade_amt")
    private BigDecimal tradeAmt;

    @ApiModelProperty(value = "变动后余额")
    @TableField("after_amt")
    private BigDecimal afterAmt;

    @ApiModelProperty(value = "提现服务费金额")
    @TableField("fee_amt")
    private BigDecimal feeAmt;

    @ApiModelProperty(value = "核算扣费")
    @TableField("check_deduct_amt")
    private BigDecimal checkDeductAmt;

    @ApiModelProperty(value = "提现实际到账金额")
    @TableField("receive_amt")
    private BigDecimal receiveAmt;

    @ApiModelProperty(value = "申请时间")
    @TableField("apply_time")
    private LocalDateTime applyTime;

    @ApiModelProperty(value = "审核时间")
    @TableField("audit_time")
    private LocalDateTime auditTime;

    @ApiModelProperty(value = "到账时间")
    @TableField("arrive_time")
    private LocalDateTime arriveTime;

    @ApiModelProperty(value = "状态（1-待审核，2-审核失败，3-审核成功，4-提现中，5-提现成功，6-提现失败）")
    @TableField("state")
    private Integer state;

    @ApiModelProperty(value = "提现失败原因")
    @TableField("refuse_reason")
    private String refuseReason;

    @ApiModelProperty(value = "调用汇付失败原因")
    @TableField("hf_fail_reason")
    private String hfFailReason;

    @ApiModelProperty(value = "请求日期")
    @TableField("req_date")
    private String reqDate;

    @ApiModelProperty(value = "请求流水号")
    @TableField("req_seq_id")
    private String reqSeqId;

    @ApiModelProperty(value = "hfId")
    @TableField("hf_id")
    private String hfId;

    @ApiModelProperty(value = "acctId")
    @TableField("acct_id")
    private String acctId;

    @ApiModelProperty(value = "取现卡序列号")
    @TableField("token_no")
    private String tokenNo;

    @ApiModelProperty(value = "创建者")
    @TableField("create_by")
    private Integer createBy;

    @ApiModelProperty(value = "创建时间")
    @TableField("create_time")
    private LocalDateTime createTime;

    @ApiModelProperty(value = "更新者")
    @TableField("update_by")
    private Integer updateBy;

    @ApiModelProperty(value = "更新时间")
    @TableField("update_time")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "备注")
    @TableField("remark")
    private String remark;

    @ApiModelProperty(value = "删除状态:0-正常，1-已删除")
    @TableField("del_state")
    private Integer delState;


}
